import request from '@/utils/request'

export default {
    getCourseInfo(courseInfo) {
        return request({
            url: `/serviceedu/course/addCourseInfo`,
            method: 'post',
            data: courseInfo
        })
    },
    getAllTeacher() {
        return request({
            url: `/serviceedu/edu-teacher/findAll`,
            method: 'get'
        })
    },
    getCourseInfoById(courseId) {
        return request({
            url: `/serviceedu/course/getCourseInfo/${courseId}`,
            method: 'get'
        })
    },
    updateCourseInfoById(courseInfo) {
        return request({
            url: `/serviceedu/course/updateCourseInfo`,
            method: 'post',
            data: courseInfo
        })
    },
    getAllCourseInfoById(courseId) {
        return request({
            url: `/serviceedu/course/getAllCourseInfo/${courseId}`,
            method: 'get'
        })
    },
    addAllCourseInfoById(courseId) {
        return request({
            url: `/serviceedu/course/addCourseInfo/${courseId}`,
            method: 'post'
        })
    },
    getAllCourseInfo(page, limit, courseQuery) {
        return request({
            url: `/serviceedu/course/pageCourseCondition/${page}/${limit}`,
            method: 'post',
            data: courseQuery
        })
    },
    delCourseInfoById(courseId) {
        return request({
            url: `/serviceedu/course/${courseId}`,
            method: 'delete'
        })
    },
}
